﻿using System;
using System.ComponentModel.DataAnnotations;
using TiaoTaoHelper.Wtm.Models;
using WalkingTec.Mvvm.Core;

namespace HengTong.Model.Db.Hr.Bill;

/// <summary>
/// 岗位分配明细表
/// </summary>
[Display(Name = "分岗明细", Description = "分岗明细表单", GroupName = "人事业务表单")]
public class SysHrJobAssignmentRequestBillEntry : BasePoco
{
    // 人员信息
    [Required]
    [Display(Name = "员工ID", Description = "关联员工主键", GroupName = "人员信息")]
    public Guid? PersonId { get; set; }

    [Display(Name = "员工", Description = "关联的员工实体", GroupName = "人员信息")]
    public SysPerson Person { get; set; }

    [Display(Name = "员工工号", Description = "员工工号", GroupName = "人员信息")]
    [StringLength(128)]
    public string StaffNo { get; set; }

    [Display(Name = "员工姓名", Description = "员工姓名", GroupName = "人员信息")]
    [StringLength(128)]
    public string Name { get; set; }
    
    [Display(Name = "工作岗位ID", Description = "关联的工作岗位ID", GroupName = "岗位信息")]
    public Guid? JobPositionId { get; set; }

    [Display(Name = "工作岗位", Description = "关联的工作岗位", GroupName = "岗位信息")]
    public SysJobPosition JobPosition { get; set; }

    [Display(Name = "所属部门ID", Description = "关联的部门ID", GroupName = "岗位信息")]
    public Guid? GroupId { get; set; }

    [Display(Name = "所属部门", Description = "关联的部门", GroupName = "岗位信息")]
    public SysGroup Group { get; set; }
    
    [Display(Name = "人事组织ID", Description = "关联的人事组织ID", GroupName = "岗位信息")]
    public Guid? OrgId { get; set; }

    [Display(Name = "人事组织", Description = "关联的人事组织", GroupName = "岗位信息")]
    public SysOrg Org { get; set; }
    
    [Display(Name = "备注", Description = "单据的备注信息", GroupName = "岗位信息")]
    [StringLength(512)]
    public string EntryRemark { get; set; }
    

    // 关联信息
    [Display(Name = "主表ID", Description = "关联的分岗申请单ID", GroupName = "关联信息")]
    public Guid? JobAssignmentId { get; set; }

    [Display(Name = "主表", Description = "关联的分岗申请单", GroupName = "关联信息")]
    public SysHrJobAssignmentRequestBill JobAssignment { get; set; }
}